﻿using System;
using Soundteller.Audio.Services;
using Soundteller.Audio.Services.Interfaces;
using Soundteller.Common.Tests;

namespace Soundteller.Audio.Tests.Unit.Services.BeatCalculatorSpecifications
{
    public abstract class BeatCalculatorTestBase : TestBase
    {
        protected IBeatCalculator BeatCalculator { get; private set; }
        protected abstract TimeSpan Time { get; }
        protected abstract double Bpm { get; }
        protected double Result { get; private set; }

        protected override void Arrange()
        {
            BeatCalculator = new BeatCalculator();
        }

        protected override void Act()
        {
            Result = BeatCalculator.Calculate(Time, Bpm);
        }
    }
}
